﻿using Microsoft.AspNetCore.Builder;
using Microsoft.Extensions.DependencyInjection;

namespace Wicture.QPZS.EPC.API.Domain
{
    public static class ApiServices
    {
        //private static ThrottlingController throttlingController;
        private static IThrottlingController _throttlingController;

        public static IApplicationBuilder UseApiServices(this IApplicationBuilder app)
        {
            _throttlingController = app.ApplicationServices.GetService<IThrottlingController>();
            _throttlingController.Init();
            //throttlingController = new ThrottlingController();
            //throttlingController.Init();

            return app;
        }
    }
}
